diff options
Diffstat (limited to 'src/pages/micro/[...page].astro')
| -rw-r--r-- | src/pages/micro/[...page].astro | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/pages/micro/[...page].astro b/src/pages/micro/[...page].astro index 8e7e814..d11d9ce 100644 --- a/src/pages/micro/[...page].astro +++ b/src/pages/micro/[...page].astro @@ -9,8 +9,10 @@ import PageLayout from "@/layouts/Base.astro"; export const getStaticPaths = (async ({ paginate }) => { const MAX_MICRO_PER_PAGE = 10; - // Get only Pleroma posts - const allMicro = await getCollection("micro").catch(() => []); // Fallback to empty array if micro collection fails + // Get only Pleroma posts tagged with "micro" + const allMicro = await getCollection("micro", ({ data }) => data.tags?.includes("micro")).catch( + () => [], + ); // Fallback to empty array if micro collection fails // Sort all micro posts const allMicroPosts = allMicro.sort( @@ -52,11 +54,11 @@ const paginationProps = { <section> <h1 class="title mb-6 flex items-center gap-3"> Micro - <a class="text-accent" href="/micro/tags/" title="Browse micro tags"> + <a class="text-accent" href="/tags/" title="Browse all tags"> <span class="sr-only">Browse tags</span> <Icon aria-hidden="true" class="h-6 w-6" focusable="false" name="mdi:tag-multiple" /> </a> - <a class="text-accent" href="/micro/rss.xml" target="_blank"> + <a class="text-accent" href="/tags/micro/rss.xml" target="_blank"> <span class="sr-only">RSS feed</span> <Icon aria-hidden="true" class="h-6 w-6" focusable="false" name="mdi:rss" /> </a> |
